<!--包含头部文件-->
{include file="public/head" /}
<body>
<nav class="breadcrumb"><i class="Hui-iconfont">&#xe67f;</i> 首页 <span class="c-gray en">&gt;</span> <a href="{:url('category/index')}">分类管理</a> <span class="c-gray en">&gt;</span> <a href="{:url('category/index')}">分类管理</a></nav>
<div class="page-container">
	<form action="{:url('category/search')}" method="post">
		<div class="text-c">
			<input type="text" class="input-text" style="width:20%" placeholder="{$search_key|default='请输入搜索关键字'}" name="cate_name">
			<button type="submit" class="btn btn-success radius"><i class="Hui-iconfont">&#xe665;</i>搜索</button>
		</div>
	</form>
	<div class="cl pd-5 bg-1 bk-gray mt-20"> 
		<span class="l"> <a class="btn btn-primary radius" href="{:url('category/add')}"><i class="Hui-iconfont">&#xe600;</i> 添加分类</a></span> 
		<span class="r tishi" style="margin-top: 7px;">注意：请谨慎删除栏目，删除栏目会删除该栏目的所有子类，以及所属商品！</span> 
	</div>
	<div class="mt-20">
		<table class="table table-border table-bordered table-bg table-hover table-sort">
			<thead>
				<tr class="text-c th">
					<th width="50">ID</th>
					<th width="150">分类名称</th>
					<th width="50">排序序号<br><span class="tishi" style="font-weight: normal;">数字越小越靠前</span></th>
					<th width="100">操作</th>
				</tr>
			</thead>
			<tbody>
				{volist name="categoryData" id="vo"}
				<tr class="text-c" id="{$vo.id}" parentid="{$vo.parent_id}">

					<td>{$vo.id}</td>
					<td style="text-align: left;{if condition='$vo.parent_id eq 0'}font-weight:bold;{/if}">

				  		<a href="{:url('content/index',array('cate_id'=>$vo.id))}" {if condition='$vo.status eq 0'}style="color: #aaa;"{/if}><?php echo str_replace($search_key,"<span style='color:#f00'>".$search_key."</span>",$vo['cate_name']);?></a>

					</td>
					<td class="text-c listorder">
						<input size="10" attr-id="{$vo.id}" attr-model="category" name="listorder"  value="{$vo.listorder}"/>
					</td>
					<td class="td-manage"><a style="text-decoration:none" class="ml-5" href="{:url('category/edit',array('id'=>$vo.id))}" title="修改"><i class="Hui-iconfont">&#xe6df;</i></a> <a style="text-decoration:none" class="ml-5" onClick="o2o_del('{:url('category/delete', ['id'=>$vo.id])}')" href="javascript:;" title="删除"><i class="Hui-iconfont">&#xe6e2;</i></a></td>
				</tr>
				{/volist}
			</tbody>
		</table>
	</div>
</div>
<!--包含头部文件-->
{include file="public/foot" /}


</body>
</html>